@mixin line-hight($number) {
    height: $number;
    line-height: $number;
}
@mixin bg($bg) {
    background: url("../../../../#{$bg}") 100% 100% no-repeat;
    background-size: cover;
}
@mixin home_lg() {
    .nav_box {
        // max-width: 15px;
        // margin: 0 auto;
        position: relative;
        box-sizing: border-box;
        padding-top: 22px;
        display: flex;
        justify-content: space-between;
        align-items: center;
        .logo {
            width: 350px;
            height: 72px;
            // margin-left: 240px;
            @include bg("assets/images/logo.png");
            background-size: contain;
            background-position: center;
        }
        .nav_logo {
            display: none;
        }
        .nav_list_box {
            min-width: 800px;
            display: flex;
            justify-content: space-between;
        }
        .nav_list {
            min-width: 780px;
            // float: left;
            color: #1f1f1f;
            font-family: Microsoft YaHei;
            font-weight: 400;
            font-size: 16px;
            @include line-hight(70px);
            .nav_active {
                display: none !important;
            }
            .nav_title {
                display: block;
                text-align: center;
                // padding: 0 32px;
                // min-width: 100px;
                padding: 0 15px;
                float: left;
                cursor: pointer;
                position: relative;
                .title {
                    img {
                        display: none;
                    }
                }
                .nav_series_bg {
                    width: 100%;
                    position: fixed;
                    left: 0;
                    z-index: 99;
                    visibility: hidden;
                    @include line-hight(89px);
                    background: rgba($color: #000000, $alpha: 0.27);
                }
                .nav_series {
                    position: absolute;
                    left: 50%;
                    transform: translate(-50%, 0);
                    // display: none;
                    visibility: hidden;
                    display: flex;
                    justify-content: center;
                    font-size: 16px;
                    z-index: 100;
                    @include line-hight(89px);

                    .nav_item_field {
                        color: #fff;
                    }
                    .nav_item_active {
                        color: #a32626;
                    }
                    .nav_item {
                        min-width: 80px;
                        padding: 0 20px;
                        color: #fff;
                        cursor: pointer;
                        text-align: center;
                        white-space: nowrap;
                    }
                }
                &:hover {
                    .title{
                        color: #a9171f;
                    }
                    .nav_series_bg {
                        visibility: visible;
                    }
                    // color: #a32626;
                    .nav_series {
                        visibility: visible;
                    }
                }
            }
        }
        .search_box{
            position: absolute;
            left: 50%;
            transform: translate(-50%,0);
            width: 640px;
            height: 65px;
            // border: 1px solid #ccc;
            display: flex;
            justify-content: space-between;
            align-content: center;
            align-items: center;
            .selectCate{
                height: 40px;
                width: 100px;
                display: flex;
            }
            .search_line1{
                flex: 1;
                display: flex;
                align-items: center;
                justify-content: flex-start;
                height: 40px;
                border-bottom: 1px solid #ccc;
            }
            .search_line2{
                flex: 1;
                display: flex;
                align-items: center;
                justify-content: flex-start;
                height: 40px;
                border-bottom: 1px solid #a32626;
            }
            input{
                flex: 1;
                height: 40px;
                line-height: 40px;
                border: none;
                border-bottom: 1px solid #ccc;
                padding-left: 15px;
                color: #666;
                &::-webkit-input-placeholder{
                    color: #bababa;
                }
            }
            .searchDelete{
                width: 40px;
                height: 40px;
                margin-right: 15px;
                // margin: 15px 15px;
                @include bg("assets/images/searchDelete.png");
                position: relative;
                &::after{
                    content: "";
                   width: 1px;
                   height: 15px;
                   position: absolute;
                   right: 0;
                   top: 50%;
                   background-color: #999;
                   transform: translate(0,-50%);
                }
            }
            .search_btn{
                width: 35px;
                height: 35px;
                @include bg("assets/images/search_pc.png");
            }
        }
        .lang {
            // position: absolute;
            // right: 0;
           width: 180px;
            display: flex;
            justify-content: flex-start;
            align-items: center;
            .lang_select {
                width: 100px;
                height: 120px;
            }
            .lang_select .el-cascader-menu {
                min-width: 100px;
            }
            .el-cascader {
                flex: 1;
                font-size: 14px !important;
                .el-input .el-input__inner {
                    padding: 0;
                    border: none !important;
                }
            }
            .search_icon {
                width: 38px;
                @include line-hight(38px);
                @include bg("assets/images/search_pc.png");
            }
            .lang_icon {
                width: 38px;
                @include line-hight(38px);
                @include bg("assets/images/lang.png");
            }
        }
        .btns {
            display: none;
        }
    }
    .el-cascader-panel {
        width: 90px;
        height: 120px;
    }
    .search-enter-active {
        animation: anSearch 1s;
      }
      /* 展开搜索框 */
      @keyframes anSearch {
        0% {
          opacity: 0;
          width: 0px;
        }
        100% {
          opacity: 1;
          width: 640px;
        }
      }
}
@mixin home_sm {
    .nav_box {
        width: 100%;
        height: 0.88rem;
        position: relative;
        font-size: 0;
        .logo {
            display: block;
            position: absolute;
            left: 50%;
            top: 50%;
            transform: translate(-50%, -50%);
            width: 2.73rem;
            height: 0.45rem;
            @include bg("assets/images/logo_mobel.png");
            background-size: contain;
            background-position: center;
        }
        .nav_list_box {
            width: 100%;
            height: auto;
            display: flex;
            flex-direction: column;
            justify-content: center;
            position: fixed;
            height: calc(100vh - 0.88rem);
            @include bg("assets/images/mobile_nav_bg.jpg");
            background-color: #fff;
            top: 0.88rem;
            z-index: 999;
            overflow-y: auto;
            .nav_logo {
                width: 1.88rem;
                margin: 0 auto;
                display: block;
            }
        }
        .home {
            display: none !important;
        }
        .nav_list {
            height: 7.6rem;
            display: flex;
            flex-wrap: wrap;
            justify-content: space-around;
            margin-top: 0.7rem;

            .nav_title {
                display: flex;
                flex-direction: column;
                justify-content: center;
                width: 3.28rem;
                height: 1.72rem;
                font-size: 0.3rem;
                color: #333333;
                box-sizing: border-box;
                padding-top: 0.6rem;
                background: rgba(255, 255, 255, 0.5);
                box-shadow: 0px 11px 21px 0px rgba(144, 144, 144, 0.22);
                border-radius: 0.08rem;
                // position: relative;
                // div{
                //     width: calc(100% - 0.21rem);
                // }
                .title {
                    text-align: center;
                    display: flex;
                    flex-direction: column;
                    align-items: center;
                    img {
                        width: 0.4rem;
                        height: 0.4rem;
                        margin-bottom: 0.15rem;
                    }
                    // justify-content: space-between;
                    // border-bottom: 0.01rem solid #ffffff;
                    padding-bottom: 0.3rem;
                    div {
                        width: 100%;
                        text-align: center;
                    }
                    // .arrows {
                    //     width: 0.21rem;
                    //     height: 0.39rem;
                    //     @include bg("../../../assets/images/mobile_naviver_you.png");
                    // }
                }
                .nav_series_bg {
                    display: none;
                }
                .nav_series {
                    display: none;
                    // display: flex;
                    flex-direction: column;
                    font-size: 0.3rem;
                    box-sizing: border-box;
                    padding: 0 0.2rem;
                    div {
                        border-bottom: 0.01rem solid rgba($color: #fff, $alpha: 0.6);
                        @include line-hight(1.25rem);
                        color: #bababa;
                    }
                }
            }
        }
        .search_box{  
            position: absolute;
            left: 50%;
            transform: translate(-50%,0);
            // width: 6.40rem;
            height: .88rem;
            // border: 1px solid #ccc;
            display: flex;
            justify-content: space-between;
            align-content: center;
            align-items: center;
            .selectCate{
                height: .40rem;
                width: 2rem;
                display: flex;
            }
            .search_line1{
                flex: 1;
                display: flex;
                align-items: center;
                justify-content: flex-start;
                height: .40rem;
                border-bottom: 0.01rem solid #ccc;
            }
            .search_line2{
                flex: 1;
                display: flex;
                align-items: center;
                justify-content: flex-start;
                height: .40rem;
                border-bottom: 0.01rem solid #a32626;
            }
            input{
                flex: 1;
                height: .40rem;
                line-height: .40rem;
                border: none;
                border-bottom: 0.01rem solid #ccc;
                padding-left: .15rem;
                color: #666;
                &::-webkit-input-placeholder{
                    color: #bababa;
                }
            }
            .searchDelete{
                width: .70rem;
                height: .70rem;
                margin-right: .15rem;
                // margin: 15px 15px;
                @include bg("assets/images/searchDelete.png");
                position: relative;
                &::after{
                    content: "";
                   width: 0.01rem;
                   height: 0.15rem;
                   position: absolute;
                   right: 0;
                   top: 50%;
                   background-color: #999;
                   transform: translate(0,-50%);
                }
            }
            .search_btn{
                width: .7rem;
                height: .7rem;
                @include bg("assets/images/search_pc.png");
            }
        }
        .lang {
            position: absolute;
            left: 0;
            top: 0;
            font-size: 0;
            display: flex;
            width: 2.3rem;
            height: 0.88rem;
            justify-content: flex-start;
            align-items: center;
            .search_icon {
                display: none;
            }
            .lang_icon {
                width: 0.3rem;
                height: 0.3rem;
                margin-left: 0.31rem;
                margin-right: 0.15rem;
                // margin-top: 0.3rem;
                // float: left;
                @include bg("assets/images/lang_mobel.png");
                // background: url("assets/images/lang_mobel.png") 100% 100% no-repeat;
                // background-size: cover;
            }
            .el-cascader {
                flex: 1;
                .el-input {
                    .el-input__suffix {
                        right: 0;
                        left: 0.3rem;
                    }
                }
            }
        }
        .search-enter-active {
            animation: anSearch 1s;
          }
          /* 展开搜索框 */
          @keyframes anSearch {
            0% {
              opacity: 0;
              width: 0px;
            }
            100% {
              opacity: 1;
              width: 100%;
            }
          }
        .btns {
            position: absolute;
            right: 0rem;
            height: 0.88rem;
            display: flex;
            align-items: center;
            justify-content: center;
            .search_icon {
                width: .5rem;
                height: .5rem;
                @include bg("assets/images/search_pc.png");
            }
            // .search {
            //     width: 0.24rem;
            //     height: 0.24rem;
            //     @include bg("assets/images/search_model.png");
            // }
            .btn {
                width: 1.31rem;
                height: 0.88rem;
                position: relative;
                &::after {
                    width: 0.31rem;
                    height: 0.22rem;
                    content: "";
                    position: absolute;
                    left: 50%;
                    top: 50%;
                    transform: translate(-50%, -50%);
                    @include bg("assets/images/btn_model.png");
                }
            }
        }
    }
}
//* 设备宽度大于 320px 小于 640px */
@media only screen and (min-width: 320px) and (max-width: 640px) {
    @include home_sm;
}
@media only screen and (min-width: 640px) and (max-width: 1199px) {
    @include home_sm;
    .nav_box {
        height: 88px;
        .lang {
            width: 160px;
            height: 88px;
            .lang_icon {
                width: 22px;
                height: 22px;
                margin-left: 31px;
                margin-right: 15px;
            }
        }
        .logo {
            width: 273px;
            height: 45px;
        }
        .nav_list_box {
            height: calc(100vh - 88px);
            top: 88px;
            .nav_logo {
                width: 200px;
            }
        }
        .nav_list {
            .nav_title {
                // width: 220px;
                width: 21%;
                .title {
                    padding-bottom: 30px;
                    img {
                        width: 40px;
                        height: 40px;
                    }
                }
            }
        }
        .btns {
            height: 88px;
            .btn {
                width: 131px;
                height: 88px;
                position: relative;
                &::after {
                    width: 31px;
                    height: 22px;
                }
            }
        }
    }
}
@media screen and (min-width: 1200px) {
    @include home_lg;
}
@media screen and (min-width: 1400px) {
    @include home_lg;
    .nav_box .nav_list .nav_title {
        // min-width: 110px;
        padding: 0 20px;
    }
}
@media screen and (min-width: 1700px) {
    // @include home_lg;
    .nav_box .nav_list .nav_title {
        // min-width: 110px;
        padding: 0 30px;
    }
}
